{$CLEO .cs}
Alloc($PLAYER_CHAR, 2)
Alloc($PLAYER_ACTOR, 3)

script_name 'ZU'

:ZU_11
wait 0
if 
  Player.IsPlaying($PLAYER_CHAR)
goto_if_false @ZU_11
if 
  $flag_player_on_mission == 0
goto_if_false @ZU_11
if 
  Char.LocateAnyMeans3D($PLAYER_ACTOR, -1622.019, -2236.893, 29.1004, 100.5, 100.5, 50.5, False)
goto_if_false @ZU_11
Streaming.LoadSpecialCharacter(1, 'ZUMBI')

:ZU_110
wait 1000
if 
  Streaming.HasSpecialCharacterLoaded(1)
goto_if_false @ZU_110
1@ = Char.Create(PedType.Mission1, 290, -1622.019, -2236.893, 29.1004)
Char.GiveWeapon(1@, 31, 9999)
Char.SetHealth(1@, 4000)
Char.SetSuffersCriticalHits(1@, False)
Char.SetHeading(1@, 76.522)
Char.SetDrownsInWater(1@, False)
Char.SetUsesUpperbodyDamageAnimsOnly(1@, True)
Char.SetDecisionMaker(1@, 32)
Char.SetAnimGroup(1@, "MAN")
Char.SetMoney(1@, 0)
Task.ToggleDuck(1@, False)
wait 8000
Task.FollowFootsteps(1@, $PLAYER_ACTOR)
Task.KillCharOnFoot(1@, $PLAYER_ACTOR)
Streaming.MarkModelAsNoLongerNeeded(290)

:ZU_251
wait 0
if 
  Player.IsPlaying($PLAYER_CHAR)
goto_if_false @ZU_325
if 
  not Char.IsDead(1@)
goto_if_false @ZU_337
if 
  Char.LocateAnyMeansChar2D($PLAYER_ACTOR, 1@, 180.0, 180.0, False)
goto_if_false @ZU_325
goto @ZU_251

:ZU_325
Char.MarkAsNoLongerNeeded(1@)
goto @ZU_11

:ZU_337
terminate_this_custom_script  
